const {DataTypes} = require("sequelize"); // 导入内置数据类型
module.exports = (sequelize, Sequelize) => {

    // 用户表
    const logs = sequelize.define("logs", {
            uid: {
                type: DataTypes.INTEGER,
                allowNull: false
            },
            label: {
                type: DataTypes.STRING,
                allowNull: false
            },
            children: {
                type: DataTypes.STRING,
                allowNull: false
            },
            color: {
                type: DataTypes.STRING,
                allowNull: false
            }
        },
        {
            freezeTableName: true
            // 强制让模型名称等于表名称
        }
    )
    return logs
}